#!/usr/bin/python
import sys
from socket import *
serverHost = "119.161.130.76" # servername is localhost
serverPort = 2345 # use arbitrary port > 1024
s = socket(AF_INET, SOCK_STREAM) # create a TCP socket
s.connect((serverHost, serverPort)) # connect to server on the port
binf=open("protocal-utf.bin",'rb')
str=binf.read()
s.send(str)
print "send successfully"
data = s.recv(1024) # receive up to 1K bytes
print "recv data",data

